package ocean.chinacraft.common.world.block.plant;

import net.minecraft.block.BambooSaplingBlock;
import net.minecraft.block.BlockState;
import net.minecraft.block.Blocks;
import net.minecraft.util.math.BlockPos;
import net.minecraft.world.server.ServerWorld;
import ocean.chinacraft.common.config.ApplicationConfig;

import java.util.Random;

/**
 * 雷笋
 *
 * @author zhang
 * @since 2022/1/5
 */
public class LightningBambooSapling extends BambooSaplingBlock {

    public LightningBambooSapling() {
        super(Properties.copy(Blocks.BAMBOO_SAPLING));
    }

    @Override
    public void randomTick(BlockState state, ServerWorld world, BlockPos pos, Random random) {
        if (ApplicationConfig.ENABLE_LIGHTNING_BAMBOO_GROWTH.get()) {
            super.randomTick(state, world, pos, random);
        }
    }
}
